package com.erp.remote.warehouse;

import com.erp.entity.sale.Sale;
import com.erp.util.AjaxResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

@RequestMapping("/warehouse/output")
public interface OutputRemote {

    @PostMapping("/outputWorkFlow")
    AjaxResult outputWorkFlow(@RequestBody Map<String,Object> map);



    /**
     * 根据销货单id获取下游单据数量
     * @param id
     * @return
     */
    @RequestMapping("/getOutputBillBySaleId")
    Integer getOutputBillBySaleId(@RequestParam("id") int id, @RequestParam("companyId") int companyId);

    /**
     * 根据销货单生成下游单据数量
     * @param sale
     * @return
     */
    @RequestMapping("/makeOutputBillBySale")
    Integer makeOutputBillBySale(@RequestParam("sale")Sale sale);


}
